﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<BookTheBook.Web.Helpers.PaginatedListCollection<BookTheBook.Data.Model.Book>>" %>

<%@ Import Namespace="BookTheBook.Data.Model" %>

<%@ Import Namespace="BookTheBook.Web.Helpers" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Books in ISDC Library
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="books">
            <%
                foreach (Book book in Model)
                   { %>
                <div class="book <%=StyleCalculator.CalculateCSSClassName(book) %>">

                <img class="image" alt="<%=book.Title %>" src="<%= Url.Action("Index", "Image", new { imageId = book.Id }) %>" height="160px;" width="118px;"/>
                
                <% Html.RenderPartial("CommonBookInfo", book); %>
                
                </div> 
            <% } %>
    </div>
    
    <% Html.RenderPartial("PaginationLibrary", Model); %>
    
</asp:Content>
